/* Copyright (c) 2004-2024 Peigen.info. All rights reserved. */

package info.peigen.hotpot.component.schedule.core.service.processor.create;

import info.peigen.hotpot.common.service.base.processor.Processor;
import info.peigen.hotpot.common.service.base.processor.ProcessorServiceContext;
import info.peigen.hotpot.component.schedule.core.domain.ScheduleJob;
import info.peigen.hotpot.component.schedule.core.service.processor.AbstractScheduleServiceProcessor;
import org.noear.solon.annotation.Component;

/**
 * <b>(ScheduleJobCreateProcessor)</b>
 *
 * @author Peigen
 * @version 1.0.0
 * @since 2023/1/6
 */
@Component
public class ScheduleJobCreateProcessor extends AbstractScheduleServiceProcessor implements Processor {
    @Override
    public Integer level() {
        return 20;
    }

    @Override
    public void execute(ProcessorServiceContext serviceContext) {
        ScheduleJob scheduleJob = ScheduleJob.create(serviceContext);
        serviceContext.setDomain(scheduleJob);
    }
}